package com.sxs.service;

import java.util.List;
import java.util.Map;

import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.sxs.dao.MenuDaoInterface;

@Service
public class MenuService implements MenuServiceInterface {
	Logger logger = Logger.getLogger(MenuService.class);
	private MenuDaoInterface mDao;

	@Autowired
	public void setmDao(MenuDaoInterface mDao) {
		this.mDao = mDao;
	}

	@Override
	public List<Map<String, Object>> createFatherMenu() {
		List<Map<String, Object>> list = mDao.getCreateFatherMenu();
		return list;
	}

	@Override
	public List<Map<String, Object>> createMenu() {
		List<Map<String, Object>> listMap = mDao.getFatherMenu();
		return listMap;
	}

	@Override
	public List<Map<String, Object>> createMenuChild(String parentCode, String jobNumber) {
		List<Map<String, Object>> listMap = mDao.getCreateMenuChild(parentCode);
		return listMap;
	}

}
